package org.misalen.web.service.sms.info;

public enum CcpInfoType {
	userRegisteredCode("sms.ccp.userRegisteredCode", "userRegistered"), //
	userFindPwdCode("sms.ccp.userFindPwdCode", "userFindPwd"),
	driverRegisteredCode("sms.ccp.driverRegisteredCode", "driverRegistered"), //
	driverFindPwdCode("sms.ccp.driverFindPwdCode", "driverFindPwd");
	public String templateId;
	public String type;

	CcpInfoType(String templateId, String type) {
		this.templateId = templateId;
		this.type = type;
	}

	public static CcpInfoType byType(String type) {
		for (CcpInfoType infoType : CcpInfoType.values()) {
			if (type.equals(infoType.type)) {
				return infoType;
			}
		}
		return null;
	}
}
